﻿using System.Text;

namespace Longbow.Net
{
    /// <summary>
    /// 异步发送配置项实体类
    /// </summary>
    public class SocketSendAsyncOptions : SocketOptions
    {
        /// <summary>
        /// 获得/设置 Socket数据长度，默认为0，即表示不用此来判断
        /// </summary>
        public int DataLength { get; set; }

        /// <summary>
        /// Gets or sets the end marks.
        /// </summary>
        /// <value>The end marks.</value>
        public byte[] EOF { get; set; } = new byte[0];

        /// <summary>
        /// Gets or sets the name of the encoding.
        /// </summary>
        /// <value>The name of the encoding.</value>
        public Encoding Encoding { get; set; } = Encoding.UTF8;

        /// <summary>
        /// 获得/设置 数据是否为16进制 默认 false
        /// </summary>
        public bool Hex { get; set; }

        /// <summary>
        /// 获得/设置 数据结尾是启用包含判断方式，默认 false
        /// </summary>
        public bool ContainerCheckModel { get; set; }
    }
}
